$(document).on("pageinit", function() {
	var nextId = 0;
	$("#add").click(function() {
		nextId++;
		var content = "<li><a href='#'>New Group" + nextId + "</a></li>";
		$("#grouplist").append(content).listview("refresh");
	});

	$("#delete").click(function() {
		$("#grouplist").children(":last").remove().listview("refresh");
	});
});

